package com.toKnow.model.vo;

import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

public class RestrictionVo {
    private Integer page;
    private String keyword;
    private String category;
    private String type;
    private List<String> tag;

    private Integer maxword;
    private Integer minword;
    private Integer minsize;
    private Integer maxsize;
    private Date expire;
    private Boolean file;
    private Integer sort;
    private Integer author_id;

    @Override
    public String toString() {
        return "RestrictionVo{" +
            "page=" + page +
            ", keyword='" + keyword + '\'' +
            ", category='" + category + '\'' +
            ", type='" + type + '\'' +
            ", tag=" + tag +
            ", maxword=" + maxword +
            ", minword=" + minword +
            ", minsize=" + minsize +
            ", maxsize=" + maxsize +
            ", expire=" + expire +
            ", file=" + file +
            ", sort=" + sort +
            ", author_id=" + author_id +
            '}';
    }

    public Integer getMinsize() {
        return minsize;
    }

    public void setMinsize(Integer minsize) {
        this.minsize = minsize;
    }

    public Integer getMaxsize() {
        return maxsize;
    }

    public void setMaxsize(Integer maxsize) {
        this.maxsize = maxsize;
    }

    public RestrictionVo(Integer page, String keyword, String category, String type, List<String> tag, Integer maxword, Integer minword, Integer minsize, Integer maxsize, Date expire, Boolean file, Integer sort, Integer author_id) {
        this.page = page;
        this.keyword = keyword;
        this.category = category;
        this.type = type;
        this.tag = tag;
        this.maxword = maxword;
        this.minword = minword;
        this.minsize = minsize;
        this.maxsize = maxsize;
        this.expire = expire;
        this.file = file;
        this.sort = sort;
        this.author_id = author_id;
    }

    public Integer getAuthor_id() {
        return author_id;
    }

    public void setAuthor_id(Integer author_id) {
        this.author_id = author_id;
    }

    public Integer getPage() {
        return page;
    }

    public void setPage(Integer page) {
        this.page = page;
    }

    public String getKeyword() {
        return keyword;
    }

    public void setKeyword(String keyword) {
        this.keyword = keyword;
    }

    public String getCategory() {
        return category;
    }

    public void setCategory(String category) {
        this.category = category;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public List<String> getTag() {
        return tag;
    }

    public void setTag(List<String> tag) {
        this.tag = tag;
    }

    public Integer getMaxword() {
        return maxword;
    }

    public void setMaxword(Integer maxword) {
        this.maxword = maxword;
    }

    public Integer getMinword() {
        return minword;
    }

    public void setMinword(Integer minword) {
        this.minword = minword;
    }

    public Date getExpire() {
        return expire;
    }

    @DateTimeFormat(pattern="yyyy-MM-dd")
    public void setExpire(Date expire) {
        this.expire = expire;
    }

    public Boolean getFile() {
        return file;
    }

    public void setFile(Boolean file) {
        this.file = file;
    }

    public Integer getSort() {
        return sort;
    }

    public void setSort(Integer sort) {
        this.sort = sort;
    }

    public RestrictionVo() {
    }

    public RestrictionVo(Integer page, String keyword, String category, String type, List<String> tag, Integer maxword, Integer minword, Date expire, Boolean file, Integer sort, Integer author_id) {
        this.page = page;
        this.keyword = keyword;
        this.category = category;
        this.type = type;
        this.tag = tag;
        this.maxword = maxword;
        this.minword = minword;
        this.expire = expire;
        this.file = file;
        this.sort = sort;
        this.author_id = author_id;
    }
}
